var $ = layui.jquery;
//
var left = $(".left");
var handle = $(".aside");

handle.on("mousedown", function (e) {
    e.preventDefault();
    var startX = e.pageX; // 记录鼠标初始位置和左侧div的宽度
    var initialLeftWidth = left.outerWidth();

    $(document).on("mousemove", function (e) {
        e.preventDefault();
        var moveX = e.pageX - startX; // 计算鼠标移动距离
        left.width(initialLeftWidth + moveX); // 更新左侧div和拖动句柄的宽度
    });

    $(document).on("mouseup", function () {
        $(document).off("mousemove").off("mouseup");
    });
});